#!/usr/bin/python
  
from ctypes import *
import os

#Define float variables, In Python, don't neet data type keyword.
i1 = 987
i2 = 1234

#import C shared library 'Cfunc.so' & named 'libCfunc'
libshr = cdll.LoadLibrary(os.getcwd() + '/build/libshr.so') 
'''
declare C function 'fadd' returned parameter's data type is 'c_double'.
declare C function 'fadd' argments' data type is 'c_float'.
'''
libshr.shared_func1.restype = c_int
libshr.shared_func1.argtypes = [c_int, c_int]

#Call C function 'fadd' in shared library 'Cfunc.so'
print libshr.shared_func1(i1, i2)